Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating docs on how to extend the tokens #33229

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

mltejera
Copy link
Contributor

@mltejera mltejera commented Nov 7, 2024

Leave's Shift's existing migration docs in place so as to not break any current links.

Copies the whole document to the current docs folder.

Takes a subset of that out and moves it to

  • The patterns folder
  • The Storybook theming section (these new docs are The Way)

@mltejera mltejera requested review from a team as code owners November 7, 2024 19:40
Copy link

github-actions bot commented Nov 7, 2024

📊 Bundle size report

✅ No changes found

Copy link

github-actions bot commented Nov 7, 2024

Pull request demo site: URL

@@ -0,0 +1,407 @@
# Migration notes from `@fluentui/[email protected]`to `@fluentui/[email protected]`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure that we want to this document in a new location. It was good in its time, some info in it is already outdated.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah agreed. The shorthands info is definitely out of date.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed this doc from the PR.


⚠ Components which use custom tokens cannot be shared between applications. Keep in mind that any application which uses a component with custom tokens must also add the custom tokens to its own themes. Instead of adding custom tokens inside potentially reusable components, you should talk to design.
⚠ Components in this repo should _not_ do this.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's in public docsite, so we probably don't need this

Comment on lines 170 to 176
```
⚠ Keep in mind that the object generated by the `themeToTokensObject()` will contain all the tokens and will not be tree-shakeable.
```

```tsx
import { themeToTokensObject } from '@fluentui/react-components';
```
export const customTokens = themeToTokensObject(customLightTheme);
```
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Delete this empty blocks?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch - removed

Copy link
Contributor

@mainframev mainframev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few typos only and suggestion is up to you 🙂

docs/react-v9/contributing/migration-notes.md Outdated Show resolved Hide resolved
docs/react-v9/contributing/migration-notes.md Outdated Show resolved Hide resolved
docs/react-v9/contributing/migration-notes.md Outdated Show resolved Hide resolved
docs/react-v9/contributing/migration-notes.md Outdated Show resolved Hide resolved
docs/react-v9/contributing/migration-notes.md Outdated Show resolved Hide resolved
@@ -0,0 +1,407 @@
# Migration notes from `@fluentui/[email protected]`to `@fluentui/[email protected]`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah agreed. The shorthands info is definitely out of date.

@mltejera mltejera force-pushed the user/matejera/move-migration-docs branch from ee9eb1f to 715fe2b Compare November 15, 2024 01:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants